﻿using System;
using System.Xml;

namespace YArchitech.HCLoad.Export
{
	internal class HcXmlRectangularGeometry
	{
		public double Azimuth
		{
			get
			{
				return this.m_dAzimuth;
			}
			set
			{
				this.m_dAzimuth = value;
			}
		}

		public double Width
		{
			get
			{
				return this.m_dWidth;
			}
			set
			{
				this.m_dWidth = value;
			}
		}

		public double Height
		{
			get
			{
				return this.m_dHeight;
			}
			set
			{
				this.m_dHeight = value;
			}
		}

		public HcXmlRectangularGeometry()
		{
			this.m_dAzimuth = 0.0;
			this.m_dWidth = 0.0;
			this.m_dHeight = 0.0;
		}

		public HcXmlRectangularGeometry(double dAzimuth, double dHeight, double dWidth)
		{
			this.m_dAzimuth = dAzimuth;
			this.m_dWidth = dWidth;
			this.m_dHeight = dHeight;
		}

		public bool WriteElementData(ref XmlElement xmlelem_RectangularGeometry)
		{
			XmlDocument ownerDocument = xmlelem_RectangularGeometry.OwnerDocument;
			HcXmlElement.AppendTextElement(ref xmlelem_RectangularGeometry, "Azimuth", this.Azimuth.ToString());
			HcXmlElement.AppendTextElement(ref xmlelem_RectangularGeometry, "Height", this.Height.ToString());
			HcXmlElement.AppendTextElement(ref xmlelem_RectangularGeometry, "Width", this.Width.ToString());
			return true;
		}

		private double m_dAzimuth;

		private double m_dHeight;

		private double m_dWidth;
	}
}
